import App from './App'
import Vue from 'vue'
import uView from 'uni_modules/uview-ui'
import apis from '@/api'
import store from '@/store';
import DictData from '@/components/dict/init'
import DictTag from '@/components/dict/DictTag'
import {hasPermission, hasRole} from "@/utils/permission";

Vue.use(uView)
Vue.config.productionTip = false
App.mpType = 'app'
Vue.prototype.$apis = apis
Vue.prototype.hasRole = hasRole
Vue.prototype.hasPermission = hasPermission

Vue.component('DictTag', DictTag);
DictData.install();
const app = new Vue({
    store, ...App
})

// 引入请求封装，将app参数传递到配置中
require('@/config/http.interceptor.js')(app)

app.$mount()